{{/* 

This shortcode lists pages that have a "feature" section configured in front matter. 

This creates a set of feature boxes as seen on the home page.

See /content/en/docs/concepts/services-networking/service.md for an example:

feature:
  title: Service discovery and load balancing
  description: >
    No need to modify your application to use an unfamiliar service discovery mechanism. Kubernetes gives containers their own IP addresses and a single DNS name for a set of containers, and can load-balance across them.

Note that markdown can be used in the description.

 */}}
<section class="features-container" id="features">
    {{- with resources.Get "images/wheel.svg" -}}
    <img class="kubernetes-logo wheel" src="{{ .RelPermalink }}" alt="">
    {{- end -}}

    <h2 class="k8s-features-heading">{{ T "main_kubernetes_features" }}</h2>
    <div>
        {{ $pages := where site.Pages ".Params.feature" "!=" nil }}
        {{ range $i, $p := $pages }}
            <div class="feature-box">
                {{ with .Params.feature }}
                <h3><a href="{{ $p.RelPermalink}}{{ with .anchor }}#{{ . | anchorize }}{{ end }}">{{ .title }}</a></h3>
                {{ $description := .description | default $p.Params.description }}
                {{ $description | markdownify }}
                {{ end }}
            </div>
        {{ end }}
    </div>
</section>
